package org.jeecg.modules.pay.service.impl;

import com.baomidou.mybatisplus.core.conditions.query.QueryWrapper;
import com.baomidou.mybatisplus.core.metadata.IPage;
import com.baomidou.mybatisplus.extension.plugins.pagination.Page;
import org.jeecg.modules.pay.entity.Resources;
import org.jeecg.modules.pay.mapper.ResourcesMapper;
import org.jeecg.modules.pay.service.IResourcesService;
import org.springframework.stereotype.Service;

import com.baomidou.mybatisplus.extension.service.impl.ServiceImpl;

/**
 * @Description: 资源表
 * @Author: jeecg-boot
 * @Date:   2022-06-14
 * @Version: V1.0
 */
@Service
public class ResourcesServiceImpl extends ServiceImpl<ResourcesMapper, Resources> implements IResourcesService {

    @Override
    public IPage<Resources> getPage(Integer pageNo, Integer pageSize, QueryWrapper<Resources> queryWrapper) {
        Page<Resources> page = new Page<Resources>(pageNo, pageSize);
        return page(page, queryWrapper);
    }

    @Override
    public void add(Resources resources) {
        save(resources);
    }

    @Override
    public void edit(Resources resources) {
        updateById(resources);
    }
}
